package cn.ncu.wechat.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;

/**
 * 小程序配置表
 * @TableName miniapp_config
 */
@TableName(value ="miniapp_config")
public class MiniappConfig {
    /**
     * 
     */
    @TableId(type = IdType.AUTO)
    private Integer versionId;

    /**
     * 
     */
    private Float versionNumber;

    /**
     * 
     */
    private Object configInfo;

    /**
     * 
     */
    private Date releaseDate;

    /**
     * 
     */
    private String publisher;

    /**
     * 
     */
    private String remarks;

    /**
     * 
     */
    public Integer getVersionId() {
        return versionId;
    }

    /**
     * 
     */
    public void setVersionId(Integer versionId) {
        this.versionId = versionId;
    }

    /**
     * 
     */
    public Float getVersionNumber() {
        return versionNumber;
    }

    /**
     * 
     */
    public void setVersionNumber(Float versionNumber) {
        this.versionNumber = versionNumber;
    }

    /**
     * 
     */
    public Object getConfigInfo() {
        return configInfo;
    }

    /**
     * 
     */
    public void setConfigInfo(Object configInfo) {
        this.configInfo = configInfo;
    }

    /**
     * 
     */
    public Date getReleaseDate() {
        return releaseDate;
    }

    /**
     * 
     */
    public void setReleaseDate(Date releaseDate) {
        this.releaseDate = releaseDate;
    }

    /**
     * 
     */
    public String getPublisher() {
        return publisher;
    }

    /**
     * 
     */
    public void setPublisher(String publisher) {
        this.publisher = publisher;
    }

    /**
     * 
     */
    public String getRemarks() {
        return remarks;
    }

    /**
     * 
     */
    public void setRemarks(String remarks) {
        this.remarks = remarks;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        MiniappConfig other = (MiniappConfig) that;
        return (this.getVersionId() == null ? other.getVersionId() == null : this.getVersionId().equals(other.getVersionId()))
            && (this.getVersionNumber() == null ? other.getVersionNumber() == null : this.getVersionNumber().equals(other.getVersionNumber()))
            && (this.getConfigInfo() == null ? other.getConfigInfo() == null : this.getConfigInfo().equals(other.getConfigInfo()))
            && (this.getReleaseDate() == null ? other.getReleaseDate() == null : this.getReleaseDate().equals(other.getReleaseDate()))
            && (this.getPublisher() == null ? other.getPublisher() == null : this.getPublisher().equals(other.getPublisher()))
            && (this.getRemarks() == null ? other.getRemarks() == null : this.getRemarks().equals(other.getRemarks()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getVersionId() == null) ? 0 : getVersionId().hashCode());
        result = prime * result + ((getVersionNumber() == null) ? 0 : getVersionNumber().hashCode());
        result = prime * result + ((getConfigInfo() == null) ? 0 : getConfigInfo().hashCode());
        result = prime * result + ((getReleaseDate() == null) ? 0 : getReleaseDate().hashCode());
        result = prime * result + ((getPublisher() == null) ? 0 : getPublisher().hashCode());
        result = prime * result + ((getRemarks() == null) ? 0 : getRemarks().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", versionId=").append(versionId);
        sb.append(", versionNumber=").append(versionNumber);
        sb.append(", configInfo=").append(configInfo);
        sb.append(", releaseDate=").append(releaseDate);
        sb.append(", publisher=").append(publisher);
        sb.append(", remarks=").append(remarks);
        sb.append("]");
        return sb.toString();
    }
}